<!doctype html>
<!-- paulirish.com/2008/conditional-stylesheets-vs-css-hacks-answer-neither/ -->
<!--[if lt IE 7 ]> <html class="no-js ie6" lang="en"> <![endif]-->
<!--[if IE 7 ]>    <html class="no-js ie7" lang="en"> <![endif]-->
<!--[if IE 8 ]>    <html class="no-js ie8" lang="en"> <![endif]-->
<!--[if (gte IE 9)|!(IE)]><!--> <html class="no-js" lang="en"> <!--<![endif]-->
<head>
  <meta charset="utf-8">

  <!-- Always force latest IE rendering engine (even in intranet) & Chrome Frame
       Remove this if you use the .htaccess -->
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">

  <title>Mad Poker Manager</title>
  <meta name="description" content="Application for managing a poker tournament">
  <meta name="author" content="Pad">

  <!-- Mobile viewport optimized: j.mp/bplateviewport -->
  <meta name="viewport" content="width=device-width, initial-scale=1.0">

  <!-- Place favicon.ico & apple-touch-icon.png in the root of your domain and delete these references -->
  <link rel="shortcut icon" href="/favicon.ico">
  <link rel="apple-touch-icon" href="/apple-touch-icon.png">


  <!-- CSS: implied media="all" -->
  <link rel="stylesheet" href="css/style.css?v=2">

  <!-- Uncomment if you are specifically targeting less enabled mobile browsers
  <link rel="stylesheet" media="handheld" href="css/handheld.css?v=2">  -->

  <!-- All JavaScript at the bottom, except for Modernizr which enables HTML5 elements & feature detects -->
  <script src="js/libs/modernizr-1.7.min.js"></script>

</head>

<body>
    <header>
		<h1>Mad Poker Manager</h1>
    </header>
	<nav class='mainmenu'>
		<ul>
			<li id='home' data-order='0' data-ownevent='home/home'>Home</li>
			<li id='tournament' data-order='1' data-ownevent='tournament/home'>Tournois</li>
			<li id='player' data-order='2' data-ownevent='players/home'>Joueurs</li>
			<li id='structure' data-order='3' data-ownevent='structures/home'>Structures</li>
			<!-- <li id='historique' data-order='4' data-event='tournament/home'>Historique</li> -->
		</ul>
	</nav>
	<section id="main">
		<div id="container">
			<article id="home">
				<h2>Section Home</h2>
				<span>Mad Poker Manager</span>
				<img id="logo" src="" alt="" />
			</article>
			
			<article id="a_tournament">
				<header>
					<h2>Section Tournament</h2>
				</header>
				<div id="d_history">
					<ul class='tournamentHistory'>
						<script id='tpl_histTournament' type='x-handlebar-template'>
							{{#each this}}
								<li>
									<span>{{date}}</span>
									<span>{{nbPlayers}} players</span>
									<span>{{winnerName}} Wins</span>
								</li>
							{{/each}}
						</script>
					</ul>
					<canvas id="b_addTournament" width="0" height="0"></canvas>
				</div>
				<form id='f_addTournament' class="addForm">
					<p class='fieldLabel'>
						<select name="i_struct" id="struct"></select>
						<label for="struct">Structure</label>
					</p>
					<p class='fieldLabel'>
						<input id="buyin" name="i_buyin" type="number" min="1000" max="1000000000" step="500" />
						<label for="buyin">Buy-In</label>
					</p>
					<p class='fieldLabel'>
						<input id="players" name="s_players" type="search" />
						<label for="players">Players</label>
					</p>
					<hr id='clear'/>
					<!-- <canvas id="b_create" width="0" height="0"></canvas> -->
					<button id="creaTournament">Create Tournament</button>
				</form>
				<div id='d_details' class="tournamentDetails">
					<script id="tpl_dtlsTournament" type="text/javascript">
							<!-- All the tournament informations organised -->
							
					</script>
				</div>
			</article>
			
			<article id="players">
				<header>
					<h2>Liste des joueurs</h2>
				</header>
				<!-- Article content -->
				
				<button id="add_player">Ajouter</button>
				<ul id='list_players' class='players'>
					
				</ul>
				<footer>
					<!-- 
						Easy player deletion from a trash zone down the player 
						list which get enabled when a user click and drag a player
						over the dedicated zone
					-->
					<canvas id="playerTrash" width="0" height="0"></canvas>
				</footer>
			</article>
			
			<article id="structures">
				<header>
					<h2>Section Structures</h2>
				</header>
				<ul id="allStructures">
					
				</ul>
				
				<footer>
				
				</footer>
			</article>
			
			
			<!--
				TODO : 	Think about the utility of this article,
						another way to do : 
							- Include this as a home for the tournament article
							- Include a way to add a tournament and then the form page to create and launch a new tournament
							-> More user friendly and logical to be welcome by the old tournament when gettin to
			-
			<article id="historique">
				<h2>Section Historique</h2>
				<table id="t_history" ></table>
			</article>
			-->
		</div>
	</section>
    <footer>
		<!-- Copyright section  Links -->
		<p>
			Copyright 2012 &copy; Pad
		</p>
    </footer>
    
    <!-- Floating navigation -->
	<img src="img/up.png" data-dir="up" alt="up" class="nav up" />
	<img src="img/down.png" data-dir="down" alt="down" class="nav down" />
	
  <!-- JavaScript at the bottom for fast page loading -->

  <!-- Grab Google CDN's jQuery, with a protocol relative URL; fall back to local if necessary -->
  <!-- <script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.js"></script> -->
  <script>window.jQuery || document.write("<script src='js/libs/jquery-1.7.2.min.js'>\x3C/script>")</script>
  <script src="http://cloud.github.com/downloads/wycats/handlebars.js/handlebars-1.0.0.beta.6.js" type="text/javascript"></script>

  <!-- scripts concatenated and minified via ant build script-->
  <script src="js/plugins.js"></script>
  <script src="js/mylibs/p4d.menuSlider.js"></script>
  <script src="js/mylibs/p4d.tournament.js"></script>
  <script src="js/script.js"></script>
  <!-- end scripts-->


  <!--[if lt IE 7 ]>
    <script src="js/libs/dd_belatedpng.js"></script>
    <script>DD_belatedPNG.fix("img, .png_bg"); // Fix any <img> or .png_bg bg-images. Also, please read goo.gl/mZiyb </script>
  <![endif]-->


  <!-- mathiasbynens.be/notes/async-analytics-snippet Change UA-XXXXX-X to be your site's ID -->
  <script>
    var _gaq=[["_setAccount","UA-XXXXX-X"],["_trackPageview"]];
    (function(d,t){var g=d.createElement(t),s=d.getElementsByTagName(t)[0];g.async=1;
    g.src=("https:"==location.protocol?"//ssl":"//www")+".google-analytics.com/ga.js";
    s.parentNode.insertBefore(g,s)}(document,"script"));
  </script>

</body>
</html>